Method and apparatus to establish communication for layer 2 switched packets with network address translation (nat)

ABSTRACT

Methods and systems according to one or more embodiments establish communication across separate IP domains that are on the same layer 2 bridged domain. In an embodiment, a method includes receiving a configuration of a first IP address of a first node on a first side of a switch and a second IP address of a second node on a second side of the switch, wherein the first and second IP addresses are of different domains and are to be translated in each direction with respect to the switch, wherein the switch further comprises an integrated block adapted to do translation at line rate. Based on the configuration, the method also includes modifying, by the switch, packets of an applicable protocol in each direction so that the first and second IP addresses are changed for each domain such that either side of the switch acts as if an opposite side is on the same domain so that layer 2 communication is established.

CROSS-REFERENCE TO RELATED APPLICATIONS

This application is a continuation of U.S. patent application Ser. No.13/686,247 filed on Nov. 27, 2012, the full disclosure of which isincorporated by reference herein in its entirety and for all purposes.

TECHNICAL FIELD

The present disclosure relates generally to computer networking, andmore specifically, to establishing communication for layer 2 switchedpackets with Network Address Translation.

BACKGROUND

Switching technologies are very important to network design because theyallow traffic to be sent only where it is needed.

A data link layer is layer 2 of the seven-layer Open SystemsInterconnection model (OSI model) of computer networking. It correspondsto, or is part of the link layer of the TCP/IP reference model. The datalink layer is the protocol layer that transfers data between adjacentnetwork nodes in a wide area network or between nodes on the same localarea network segment. The data link layer provides the functional andprocedural means to transfer data between network entities and mayprovide the means to detect and possibly correct errors that may occurin the physical layer. Examples of data link protocols include Ethernetfor local area networks (multi-node) and Point-to-Point Protocol (PPP).

In general, layer 2 switching is hardware-based, which means it usesmedia access control address (MAC address) from a host's networkinterface cards (NICs) to decide where to forward frames. Switches mayuse application-specific integrated circuits (ASICs) to build andmaintain forwarding tables (also known as MAC address tables). A layer 2switch may be considered to be similar to a multiport bridge.

In computer networking, network address translation (NAT) is a processfor modifying IP address information in IP packet headers while intransit across a traffic routing device.

On devices that use ASICs to switch packets at layer 2 of the OSI model,one way to implement NAT is to process packets in the CPU or to add anFPGA component to achieve line rate performance. However, due to thelayer 3 nature of NAT, packets flowing across a NAT boundary from one IPsub domain to another while maintaining the same layer 2 domainstructure may lead to breakdown of conventional communication betweennetwork nodes. This is mainly because a protocol such as AddressResolution Protocol (ARP) may not work as expected in this scenario.

BRIEF DESCRIPTION OF THE DRAWINGS

FIG. 1 is a diagram illustrating a layer 2 NAT (L2 NAT) system overviewaccording to an embodiment of the present disclosure.

FIG. 1A is a block diagram illustrating the L2 NAT device 111 of thesystem of FIG. 1 according to an embodiment of the present disclosure.

FIG. 2 is a flow diagram illustrating a method for establishing layer 2initial communication across separate IP domains on the same layer 2bridged domain according to an embodiment of the present disclosure;

FIG. 3 is a diagram illustrating a switch used in a networkconfiguration using NAT for communication between one or more machinenodes and one or more elements beyond a router according to anembodiment of the present disclosure;

FIG. 4 is a diagram illustrating a switch used in a networkconfiguration using NAT for communication between one or more machinenodes and one or more elements beyond the switch according to anembodiment of the present disclosure;

FIG. 5 is a diagram illustrating a switch used in a networkconfiguration using NAT for communication between a first machine nodeand a second machine node according to an embodiment of the presentdisclosure; and

FIG. 6 is a flow diagram illustrating a method for generallyestablishing layer 2 initial communication according to an embodiment ofthe present disclosure.

Embodiments of the present disclosure and their advantages are bestunderstood by referring to the detailed description that follows. Itshould be appreciated that like reference numerals are used to identifylike elements illustrated in one or more of the figures.

DETAILED DESCRIPTION OF EXAMPLE EMBODIMENTS

Overview

Methods and systems for establishing communication for layer 2 switchedpackets with Network Address Translation (NAT) in computer networkingare disclosed according to one or more embodiments. Certain protocolslike ARP (Address Resolution Protocol), ICMP (Internet Control MessageProtocol), etc. may not work transparently across layer 2 NAT(hereinafter referred to as “L2 NAT”). In embodiments herein, for simpleswitching applications such as those used in Industrial Ethernet (IE),issues of breakdown of conventional communication between network nodesmay be addressed by “fixing up” the applicable protocol such as ARP.

In one or more embodiments, a user configures IP addresses that are tobe translated in each direction to/from opposite sides of a switch. Itshould be noted that in embodiments herein, “side” or “sides” of aswitch may refer to either a public or private link of, for example, anEthernet switch. Based on this configuration, the switch modifiesapplicable protocol packets (“fix up”), e.g., ARP packets, in eachdirection so that the IP addresses may be changed for each domain orsubnet, thereby “tricking” each side to think that the other side is onthe same subnet. As such, embodiments of the present disclosure mayestablish initial communication across separate IP subnets or domains onthe same layer 2 bridged domain. This may be used if NAT is desired onbridged or switched packets.

Advantageously, one or more embodiments herein may not require anapplicable protocol proxy agent such as an ARP proxy agent to establishlayer 2 communication for NAT'ed packets. Instead, outgoing and incomingprotocol packets such as ARP packets may be modified to accomplish thecommunication, thus only involving minimal user configuration and quickdata path processing.

Example Embodiments

Referring to FIG. 1, a diagram illustrating a layer 2 NAT (L2 NAT)system overview is shown according to an embodiment of the presentdisclosure.

A user 101 may use a user interface 105 to control the configuration ofone or more switch components including a switch device 109, a L2 NATdevice 111 and/or one or more physical layer devices 113. A processor107 is a computational device that may allow user 101 to control theswitch's components and report status to the user.

Switch device 109 may perform all layer 2 switching operations,including how to forward incoming packets.

L2 NAT device 111 may perform line rate IP address translation ofpackets as they flow through the switch components. In one or moreembodiments, L2 NAT device 111 may include logic circuitry to facilitatetransparent IP address translations including, for example, ARP andICMP, as may be provisioned by system software.

Physical layer device(s) 113 may provide an interface to a physicalmedium. For example, Ethernet, which may be defined to operate over bothcopper, optical fiber, and/or other appropriate mediums.

In general, a control path flow may involve a flow from user 101 viauser interface 105 to processor 107 to switch device 109, NAT device111, and Physical Layer Devices(s) 113. A packet path flow may involve aflow from switch device 109 to NAT device 111 to Physical LayerDevice(s) 113 to a network such as a Local Area Network 115. It shouldbe understood that a control path may flow in a reverse direction, forexample, to provide status or reports to user 101. Similarly, a packetpath may be bi-directional and flow in a reverse direction (e.g., to orfrom one node to another).

Referring to FIG. 1A, a block diagram illustrating the L2 NAT device 111of the system of FIG. 1 is shown according to an embodiment of thepresent disclosure.

In one or more embodiments, the L2 NAT device 111 may comprise variousblocks including a parser 121, an instance table 123, a translationtable 125, a permit/discard block 127, a Fixup block 129, a statisticsblock 131 and a processor interface 133.

Parser 121 may determine the type of packet that may be incoming so thatdownstream blocks may process the packet properly based on softwareprovisioning of the system. For example, if an ARP packet is recognized,then Fixup block 129 may be informed that extra processing (e.g., bothsource and destination address translation) may be required for thispacket.

For each packet interface, which may be defined by e.g., port/VLANcombination, various controls may be provisioned by user 101 in InstanceTable 123 regarding the desired handling of an incoming packet. Thesecontrols may include, for example: whether various protocols require“inside” or “outside” translation; which protocols require NAT support;and/or whether various protocol messages should be forwarded ordiscarded. For example, if a packet's IP address does not match an entryin Translation Table 125, it may be optionally discarded or forwarded.Translation Table 125 may use the VLAN ID, and port as a key, and mayreport the corresponding controls so that packets matching the key maybe processed as desired.

Translation Table 125 may define all or some of the desired IP addresstranslations. After parser 121 extracts the IP addresses of the incomingpackets, Translation Table 125 may be searched for a matching entry. Ifthere is a match, the translated address may be reported so Fixup block129 may make a required substitution.

Based on the settings of Instance Table 123, certain protocols of aninstance (or packets not matching Translation Table 125 entries) may beflagged for “discard” at Permit/Discard block 127. That is, packetsmatching a programmed description are not forwarded. Conversely, packetsnot matching the programmed description are permitted or forwarded.Advantageously, this may be useful for filtering out extraneousmessages, and for preventing improper behavior in the system or network.

Fixup block 129 may perform IP address translations both in an IP headerand in a payload of selected protocols (e.g., ARP, ICMP, etc.). Also,Fixup block 129 may correct header checksums, and layer 2 CylicRedundancy Checks [CRC] so that downstream devices will not discard thetranslated packet.

Statistics block 131 may implement information about the behavior of thesystem. For instance, user 101 may access the count of various types ofevents such as total packets, ARP fixups, dropped packets, etc. As such,the behavior of the system may be monitored.

Processor Interface 133 may provide a way for communication with thesystem processor 107 for control and monitoring of the system.

In an embodiment wherein a first network includes a node A, which mayhave a “private” IP address and is positioned on one side of a switch,for example, connected on an internal link of an Ethernet switch (i.e.,downlink ports), and a second device includes a node B, which may have a“public” IP address and is positioned on another side of the switch, forexample, connected to an external entity (e.g., an external node of adevice or a network) using an external link of the same Ethernet switch(i.e., uplink port), it may be desirable to establish a switched layer 2connection between Node A and Node B across the switch. It should benoted that in embodiments herein, “side” may refer to either an internalor external link of, for example, an Ethernet switch.

To establish layer 2 communication with devices or networks in the sameswitching domain or subnet, the TCP/IP stack of Node A uses anapplicable protocol, for example, ARP. However, protocols such as ARPmay generally only be used for devices with IP addresses on the samesubnet, for example, only for private IP addresses. In an embodimentwhere the IP address of Node B is a public address, ARP may not be usedas is because Node B is on a different subnet. As such, Node B may needanother representation of its public IP address in the private subnet sothat Node A treats the destination IP address of node B as being on thesame subnet as itself, thus being able to use ARP.

In an embodiment, Node A may be informed of the internal representationof the external IP address. For example, the public IP address of Node Bmay be represented in the private subnet. Node A may then use ARP forthat address as it is now on the same subnet with an ARP request. Beforeforwarding an ARP packet, the switch changes both the embedded sourceand destination IP addresses in the ARP request from “private” to“public” so that node B sees the expected addresses. Node B then getsthe ARP request, recognizes its “public” IP address in the ARP request,and responds with its MAC address. Node B may also store the “public”representation of node A along with its MAC address in its ARP cache.The switch sees this ARP response, and forwards it back to node A, butnow it changes both the embedded source and destination IP addresses inthe ARP response from “public” to “private.” Node A receives the ARPresponse and recognizes both source and destination IP addresses to bein the same “private” subnet, and learns the MAC address of Node B.Thus, layer 2 communication may be initially established.

As such, a user may configure source and destination IP addresses ofrespective nodes at each side of a switch wherein the IP addresses areof different domains and need to be translated in each direction. Forinstance, a user may configure the IP address translation that may beneeded for both source AND destination IP addresses for packets goingfrom the private network to the public network. Because thiscommunication may be bi-directional, the same entries may be used fortraffic in an opposite direction with source and destination IPaddresses swapped.

Referring to FIG. 2, a flow diagram illustrates a method forestablishing layer 2 initial communication across separate IP domains onthe same layer 2 bridged domain according to an embodiment of thepresent disclosure. The method of the embodiment of FIG. 2 may beimplemented by the system illustrated in the embodiment of FIG. 1.

In block 202, a first node in a first subnet having for example aprivate IP address is informed of the internal representation of anexternal IP address of a second node in a second subnet having forexample a public IP address.

In block 204, an applicable protocol, for example ARP, is used for theIP address of the second node, wherein the second node IP address is ona same subnet with an ARP request.

In block 206, both embedded source and destination IP addresses arechanged in the ARP request, for example from “private” to “public” sothe second node sees the expected addresses.

In block 208, the ARP packet is forwarded, e.g., by a switch, to thesecond node, wherein the second node gets the ARP request, recognizesits subnet IP address, for example “public” IP address, in the ARPrequest, and responds with its MAC address. The second node may alsostore the subnet representation, for example “public” representation, ofthe first node along with its MAC address in its ARP cache.

In block 210, the ARP response is forwarded, e.g., by the switch, to thefirst node changing both the embedded source and destination IPaddresses in the ARP response from the second subnet to the first subnetof the first node, for example from “public” to “private”. The firstnode receives the ARP response and recognizes both source anddestination IP addresses to be in the same subnet, for example “private”domain, and learns the MAC address of the second node so that layer 2communication is established.

For this to happen, a user may configure the IP address translation tobe used for both source AND destination IP addresses for packets goingfrom one subnet to another, for example, from the private network to thepublic network. The communication is bi-directional, therefore, the sameentries may be used for traffic in the opposite direction with sourceand destination IP addresses swapped.

As such, embodiments of the present disclosure may establish initialcommunication across separate IP subnets or domains on the same layer 2bridged domain. This may be used if NAT is desired on bridged orswitched packets.

Advantageously, embodiments herein may not require an applicableprotocol proxy agent, for example an ARP proxy agent, to establish layer2 communication for NAT'ed packets. Instead, outgoing and incomingpackets (e.g., ARP packets) are modified to accomplish thecommunication, thus only involving minimal user configuration and linerate data path processing.

In this regard, for example, if an interface is Gigabit Ethernet, framesare generally translated at Gigabit per second speed. Generally, ifsoftware processes the frames, this process may be much slower (not linerate). There is no guarantee of line rate translation because it dependson CPU processing power. In embodiments herein, which may comprise ahardware solution, advantageously, the processor may be freed of thiscomputationally-intensive work, to perform other important tasks.

Referring to FIG. 3, a switch used in a network configuration using NATfor communication between one or more machine nodes and one or moreelements beyond a router is illustrated according to an embodiment ofthe present disclosure.

In one or more embodiments, a machine level switch (“MLS”) such as amachine-level Industrial Ethernet (IE) switch may be used in certainnetwork configurations that may require supporting IP Network AddressTranslation (NAT) in Layer 2 switched configurations in networks such asIE networks.

In general, deployments such as Industrial Ethernet deployments mayinclude machine nodes and external controlling entities such as LineControllers (LCs). Machine nodes may usually be connected on theinternal links of an Ethernet switch located close to the nodes. Thisswitch aggregates the internal traffic and switches it to the externalentities using “uplinks”. These machine nodes come up withpre-configured IP addresses in most deployments, which may lead to theissue that multiple nodes may come up with duplicate IP addresses. Thisrequires a NAT mechanism so that addresses appearing on the uplinks areunique. A switch based platform, for example as part of an ASIC, may beused, and because it does not have any inbuilt NAT functionality, anintegrated circuit (such as an ASIC or FPGA) translates IP addressesexternal to Layer 2 switching. For ingress packets NAT occurs beforeLayer 2 switching, and for egress packets NAT occurs after Layer 2switching. In various embodiments, it may also be possible to integratethe Layer 2 switching and NAT functionality into a single device.

As described above, certain protocols like ARP, ICMP, etc. may not worktransparently across L2 NAT. These protocols may be “fixed up” using,for example, Application Layer Gateways (ALG), or an integrated circuitdevice such as FPGA, which may provide line rate translation.

Network configuration 300 illustrated in the embodiment of FIG. 3 showscommunications between one or more machine nodes and one or moreelements beyond a router. For example, network configuration 300 showscommunications between a node A1, which is on one side of a router 302,and an external element such as a human machine interface (HMI) 304(e.g., a computer) or a Line Controller (LC) 306, which are beyondrouter 302. In an embodiment, an Aggregation Switch (AS) such as anIndustrial Ethernet Aggregation Switch may act as router 302.

A network between MLS-A 308, MLS-B 310 and AS or router 302 is a“NAT'ed” network with unique IP addresses.

In this embodiment, a default router may be configured on node A1 as192.168.1.254, which may actually represent 10.1.1.254. Globalconfiguration may be done, for example, with an inside command using192.168.1.1 to 10.1.1.1, and an outside command using 10.1.1.254 to192.168.1.254. The configuration may be applied on the uplink andprotocol (e.g., ARP) “fixup” may be enabled by default. When node A1wants to communicate with LC 306, for example, it ARPs for DefaultGateway with an embedded source IP address as 192.168.1.1 and adestination IP address as 192.168.1.254.

MLS-A 308 “fixes up” an ARP request so that the source IP address ischanged to 10.1.1.1 and the destination IP address is changed to10.1.1.254. MAC addresses are untouched.

AS 302 (or other router) receives the ARP request, and learns the MACaddress corresponding to address 10.1.1.1, which actually representsnode A1.

AS 302 sends an ARP response with embedded source IP address 10.1.1.254and destination IP address as 10.1.1.1

MLS-A 308 “fixes up” the ARP response so that the source IP address isshown as 192.168.1.254, and the destination IP address is shown as192.168.1.1.

Node A1 learns the MAC address corresponding to 192.168.1.254, whichactually represents AS 302, and communication starts.

All data communication between a machine node and an external element,for example, between node A1 and LC 306 may have the LC's actual IPaddress (200.1.1.1) as the destination address. This does not need a NATtranslation entry.

A similar flow may occur if initial communication is originated from theexternal element, for example, from LC 306.

Notably, communication to a management interface (e.g., 10.1.1.100configured on a switch virtual interface (SVI) on MLS-A 308) isunaffected by NAT.

The above configuration according to one or more embodiments may useboth “inside” and “outside” address configurations. However, analternate configuration according to an embodiment may be done withoutthe “outside” address configuration if the same subnet is divided into aunique and a portion.

In the alternate configuration the same subnet may be divided in anexternal and internal address space. Notably, an “uplink” address spaceis in the same subnet as the machine address space. However, the uplinkaddress space has unique addresses only which are different from themachine level addresses.

Similar to the embodiment illustrated in FIG. 3, communication may bebetween a node A1 and a Line Controller 306 or HMI 304, which are beyondrouter 302. The network between the MLSs 308 or 310 and AS 302 is the“NAT'ed” network with unique IP addresses.

In this alternate embodiment, a Default Router may be configured on nodeA1 as, for example, 192.168.1.254. Global configuration may be, on theinside, 192.168.1.1 192.168.1.101—“192.168.1.101” is in the “unique”address range, while “192.168.1.1” is in the duplicate address range. Itshould be noted that an “outside” command for this configuration is notneeded. The configuration may then be applied on the uplink. ARP “fixup”is enabled by default.

When node A1 wants to communicate with an external node or entity suchas LC 306, it ARPs for Default Gateway with embedded source IP as192.168.1.1 and destination IP as 192.168.1.254. MLS-A 308 “fixes up”the ARP request so that the source IP is changed to 192.168.1.101 andthe destination IP is untouched. MAC addresses are untouched.

AS 302 (or other router) receives the ARP request and learns the MACaddress corresponding to 192.168.1.101, which actually represents nodeA1.

AS 302 sends an ARP response with embedded source IP 192.168.1.254 anddestination IP as 192.168.1.101.

MLS-A 308 “fixes up” the ARP response so the destination IP is shown as192.168.1.1. The source IP is untouched.

Node A1 learns the MAC address corresponding to 192.168.1.254, whichactually represents AS 302, and communication starts.

A similar flow may occur if initial communication is originated from L.C306.

Also, communication to a management interface, which may have, forexample an IP 192.168.1.150, is possible from both the internal networkand external network.

Referring now to FIG. 4, a switch used in a network configuration usingNAT for communication between one or more machine nodes and one or moreelements beyond the switch is illustrated according to an embodiment ofthe present disclosure.

In network configuration 400, communication is shown between a machinenode A1 and a Line Controller (LC) 406, which is directly connected toan MLS-A 408 uplink.

For global configuration on MLS-A 408, an inside address command may use192.168.1.1 10.1.1.1, and an outside address command may use 10.1.1.200192.168.1.250. The configuration may be applied on the uplink.Applicable protocol “fixup” such as ARP “fixup” may be enabled bydefault.

When node A1 wants to communicate with LC 406, it ARPs, for example, forLC 406 with embedded source IP as 192.168.1.1 and destination IP as192.168.1.250.

MLS-A 408 “fixes up” the ARP request so that the source IP is changed to10.1.1.1 and the destination IP is changed to 10.1.1.200. MAC addressesare untouched.

LC 406 receives the ARP request and learns the MAC address correspondingto 10.1.1.1, which actually represents node A1.

LC 406 sends an ARP response with embedded source IP 10.1.1.200 anddestination 10.1.1.1.

MLS-A 408 “fixes up” the ARP response so that the source IP is changedto 192.168.1.250, and the destination IP is changed to 192.168.1.1.

Node A1 learns the MAC address corresponding to 192.168.1.250, whichactually represents LC 406, and communication starts.

A similar flow may occur if initial communication is originated from LC406.

Also, a configuration similar to the alternate configuration describedabove may be possible if internal and external addresses are in the samesubnet. That is, whereas the embodiment of FIG. 4 may use both “inside”and “outside” address configurations, an alternate configurationaccording to an embodiment may be done without the “outside” addressconfiguration if the same subnet is divided into a unique and non-uniqueportion.

Referring now to FIG. 5, a switch used in a network configuration usingNAT for communication between a first machine node and a second machinenode is illustrated according to an embodiment of the presentdisclosure.

Network communication 500 shows communication between machine nodes A1and B1 with duplicate IP addresses, and which are connected to MLS-A 508and MLS-B 509, respectively. AS 502 may act as a router for LCcommunication, but is switching traffic between MLS-A 508 and MLS-B 509.Network between the MLSs 508, 509 and AS 502 is a “NAT'ed” network withunique IP addresses.

Default Router may be configured on node A1 as 192.168.1.254, whichactually represents 10.1.1.254. The same is true for node B1. 10.1.1.254may be configured as an SVI so that this is shared as a common defaultgateway across the MLS network.

For global configuration on MLS-A 508, an inside address may be192.168.1.1 10.1.1.1, and an outside address may be 10.1.1.254192.168.1.254. Outside 10.1.1.21 192.168.1.253—10.1.1.21 should have amatching “inside” configuration on MLS-B 509. The configuration may thenbe applied on the uplink.

For global configuration on MLS-B 509, an inside address may be192.168.1.1 10.1.1.21, and an outside address may be 10.1.1.254192.168.1.254. Outside 10.1.1.1 192.168.1.253—10.1.1.1 should have amatching “inside” configuration on MLS-A 508. The configuration may thenbe applied on the uplink.

Note that for node A1 to communicate with node B1, MLS-A 508 and MLS-B509 may have symmetric configurations for each direction.

ARP fixup is enabled by default. When node A1 wants to communicate withnode B1, it may ARP for node B1 with an embedded source IP as192.168.1.1 and a destination IP as 192.168.1.253.

MLS-A 508 “fixes up” the ARP request so that the source IP is changed to10.1.1.1 and destination IP is changed to 10.1.1.21. MAC addresses areuntouched.

MLS-B 509 “fixes up” the ARP request so that the source IP is changed to192.168.1.253 and the destination IP is changed to 192.168.1.1. MACaddresses are untouched.

Node B1 receives the ARP request and learns the MAC addresscorresponding 192.168.1.253, which actually represents node A1.

Node B1 sends an ARP response with embedded source IP 192.168.1.1 anddestination IP as 192.168.1.253.

MLS-B 509 “fixes up” the ARP response so that the source IP is changedto 10.1.1.21 and the destination IP is changed to 10.1.1.1.

MLS-A 508 “fixes up” the ARP response so that the source IP is changedto 192.168.1.253, and the destination IP is changed to 192.168.1.1.

Node A1 learns the MAC address corresponding to 192.168.1.253, whichactually represents B1, and communication starts.

A similar flow may occur if initial communication is originated fromnode B1.

Note that IP 192.168.1.253 may be intentionally duplicated in both MLS-A508 and MLS-B 509 private networks. In this case, communication may beprovided when corresponding “public” addresses are unique.

Also, in this case, a configuration similar to the alternateconfiguration described above may be possible if internal and externaladdresses are in the same subnet. That is, whereas the embodiment ofFIG. 5 may use both “inside” and “outside” address configurations, analternate configuration according to an embodiment may be done withoutthe “outside” address configuration if the same subnet is divided into aunique and non-unique portion.

In embodiments of the present disclosure, other network configurationsmay provide communication between one or more machine nodes and one ormore elements such as LCs with duplicate IP addresses. Also, networkconfigurations according to an embodiment may provide communicationbetween a machine node and an outside network through an internalrouter. For example, communication may be provided between a node, whichis behind a router in the machine network, and a Line Controller or HMI,which is beyond another router. In further embodiments, alternateconfigurations may also be possible if internal and external addressesare in the same subnet.

Referring to FIG. 6, a flow diagram illustrates a method for generallyestablishing layer 2 initial communication according to an embodiment ofthe present disclosure. The method of FIG. 6 may be implemented by anyof the configurations illustrated in FIG. 1, 3, 4 or 5 according to oneor more embodiments.

In block 602, a user may configure IP addresses that need to betranslated in each direction. For instance, source and destination IPaddresses of respective nodes at each side of a switch may beconfigured, wherein the IP addresses are of different domains and needto be translated in each direction. In various embodiments, the “switch”may include an integrated hardware block that may do NAT at line rate.For example, as described above with respect to the embodiments of FIGS.1 and 1A, the “switch” may include a typical switch such as an ASIC plusa NAT device. In an embodiment, the “switch” may include an ASIC switchplus an FPGA.

In block 604, applicable protocol packets, for example ARP packets maybe modified in each direction so IP addresses are changed for eachdomain. That is, based on the configuration, the switch modifiesapplicable protocol packets, for example, ARP packets, in each direction(“fixup”) so that the IP addresses are changed for each domain, thereby“tricking” each side to think that the other side is on the same domainor subnet.

One or more embodiments herein may aid in establishing communicationacross separate IP domains on the same layer 2 bridged domain, which mayarise in scenarios where NAT may be desired on bridged or switchedpackets. Embodiments herein do not require an applicable protocol proxyagent, for example an ARP proxy agent, to establish layer 2communication for NAT'ed packets. Instead, outgoing and incomingpackets, e.g., ARP packets, are modified to accomplish this, whichrequires minimal user configuration and some quick, line rate data pathprocessing.

Therefore, it should be understood that embodiments herein may bepracticed with modification and alteration within the spirit and scopeof the appended claims. The description is not intended to be exhaustiveor to limit the disclosure to the precise form disclosed. It should beunderstood that the disclosure may be practiced with modification andalteration and that the disclosure be limited only by the claims and theequivalents thereof.

1. An Industrial Ethernet switch comprising: a downlink port configuredto receive traffic from a first machine node with a pre-configured IPaddress; an uplink port configured to transmit the received traffic toan external entity; and one or more processors coupled between thedownlink port and the uplink port and configured to perform networkaddress translation on the received traffic, wherein the network addresstranslation includes: determining whether the received traffic includesa protocol packet of a protocol that does not work transparently acrossthe network address translation; and modifying a payload of the protocolpacket when the received traffic includes the protocol packet.
 2. TheIndustrial Ethernet switch of claim 1, wherein the pre-configured IPaddress is selected from a duplicate address range.
 3. The IndustrialEthernet switch of claim 2, wherein the network address translationincludes translating the pre-configured IP address to a unique IPaddress selected from a unique address range.
 4. The Industrial Ethernetswitch of claim 1, wherein the protocol packet includes one or more ofan address resolution protocol (ARP) packet or an Internet controlmessage protocol (ICMP) packet.
 5. The Industrial Ethernet switch ofclaim 1, wherein the network address translation includes layer 2network address translation (L2 NAT).
 6. The Industrial Ethernet switchof claim 1, wherein modifying the payload of the protocol packet isperformed at a line rate of the Industrial Ethernet switch.
 7. TheIndustrial Ethernet switch of claim 1, wherein modifying the payload ofthe protocol packet is performed without a protocol proxy agent.
 8. TheIndustrial Ethernet switch of claim 1, wherein modifying the payload ofthe protocol packet includes correcting a cyclic redundancy check of theprotocol packet.
 9. The Industrial Ethernet switch of claim 1, whereinmodifying the payload of the protocol packet includes changing anembedded source IP address of the protocol packet without changing anembedded destination IP address of the protocol packet.
 10. TheIndustrial Ethernet switch of claim 1, wherein modifying the payload ofthe protocol packet includes changing an embedded source IP address ofthe protocol packet and an embedded destination IP address of theprotocol packet.
 11. The Industrial Ethernet switch of claim 1, whereinmodifying the payload of the protocol packet does not change any MACaddresses of the protocol packet.
 12. The Industrial Ethernet switch ofclaim 1, wherein the external entity includes an Industrial EthernetAggregation Switch.
 13. The Industrial Ethernet switch of claim 1,wherein the downlink port is further configured to receive traffic froma second machine node that shares the pre-configured IP address.
 14. Amethod comprising: receiving, via one or more downlink ports of anIndustrial Ethernet switch, traffic from one or more machine nodes withpre-configured IP addresses; performing network address translation onthe received traffic; determining whether the received traffic includesa protocol packet of a protocol that does not work transparently acrossthe network address translation; fixing up the protocol packet bymodifying a payload of the protocol packet when the received trafficincludes the protocol packet; and transmitting, via one or more uplinkports of the Industrial Ethernet switch, the received traffic to one ormore external entities.
 15. The method of claim 14, wherein thepre-configured IP addresses are selected from a duplicate address range,and wherein performing the network address translation includestranslating the pre-configured IP addresses to unique IP addressesselected from a unique address range.
 16. The method of claim 14,wherein modifying the payload of the protocol packet includes changingan embedded source IP address of the protocol packet without changing anembedded destination IP address of the protocol packet.
 17. The methodof claim 16, wherein modifying the payload of the protocol packetincludes correcting a cyclic redundancy check of the protocol packet.18. The method of claim 14, wherein fixing up the protocol packet isperformed at a line rate of the Industrial Ethernet switch.
 19. A systemcomprising: a first machine node with a first pre-configured IP address;a second machine node with a second pre-configured IP address; anIndustrial Ethernet switch coupled to the first machine node and thesecond machine node, wherein the Industrial Ethernet switch isconfigured to: receive traffic from the first and second machine nodes;transmit the received traffic over one or more uplinks; and when thefirst and second pre-configured IP addresses are duplicate IP addresses,perform network address translation on the received traffic, wherein thenetwork address translation includes: determining whether the receivedtraffic includes a protocol packet of a protocol that does not worktransparently across the network address translation; and modifying apayload of the protocol packet when the received traffic includes theprotocol packet.
 20. The system of claim 19, wherein modifying thepayload of the protocol packet includes changing an embedded source IPaddress of the protocol packet to a unique IP address without changingan embedded destination IP address of the protocol packet.